
package org.winexpress

/**
 *
 * @author Swee Zhi
 */
class Customer {	
    // attributes
    int id
    
    String username
    String password
    Date lastLogin
    boolean activationStatus
    
    String lastName
    String firstName
    Date birthdate
    
    String blkHouseNo
    String streetName
    String postalCode
    String telNo
    
    String countryId
    
    static constraints = {
        id(blank:false, unique:true)
        username(blank:false, unique:true)
        password(blank:false)
        lastLogin(blank:true)
    }
    
//    static hasOne = [country:Country]
    static hasMany = [ratingComment:RatingComment]
}

